package com.sg.dto.integration.app;

import com.sg.common.dto.BaseDto;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;
import java.util.Objects;

/**
 * @desc AchievementTypeDto
 * @使用场景
 */
@Data
public class AchievementTypeDto extends BaseDto implements Serializable {

    /**
     * 成果类型ID
     */
    @ApiModelProperty("成果类型ID")
    private String achievementTypeId;

    /**
     * 成果类型编号
     */
    @ApiModelProperty("成果类型编号")
    private String achievementTypeNumber;

    /**
     * 成果类型名称
     */
    @ApiModelProperty("成果类型名称")
    private String achievementTypeName;

    /**
     * 成果类型介绍
     */
    @ApiModelProperty("成果类型介绍")
    private String achievementDesc;

    /**
     * 是否标准成果类型 TRUE:是 FALSE:否
     */
    @ApiModelProperty("是否标准成果类型")
    private String isStandard;

    /**
     * 版权归属别名
     */
    @ApiModelProperty("版权归属别名")
    private String belongName;

    /**
     * 主体生命周期 CURRENTLY_VALID:当前有效 EDITING:正在编辑 ARCHIVING:历史存档
     */
    @ApiModelProperty("主体生命周期")
    private String subjectLifeCycle;

    /**
     * 操作人就职记录ID
     */
    @ApiModelProperty("操作人就职记录ID")
    private String operationInductionId;

    /**
     * 操作时间
     */
    @ApiModelProperty("操作时间")
    private Date operateTime;

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        if (!super.equals(o)) return false;
        AchievementTypeDto that = (AchievementTypeDto) o;
        return (
                achievementTypeId == that.achievementTypeId &&
                        achievementTypeNumber == that.achievementTypeNumber &&
                        achievementTypeName == that.achievementTypeName &&
                        achievementDesc == that.achievementDesc &&
                        isStandard == that.isStandard &&
                        belongName == that.belongName &&
                        subjectLifeCycle == that.subjectLifeCycle &&
                        operationInductionId == that.operationInductionId &&
                        operateTime == that.operateTime
        );
    }

    @Override
    public int hashCode() {
        return Objects.hash(
                super.hashCode(),
                achievementTypeId,
                achievementTypeNumber,
                achievementTypeName,
                achievementDesc,
                isStandard,
                belongName,
                subjectLifeCycle,
                operationInductionId,
                operateTime
        );
    }

}
